package com.easy.query.test.entity.proxy;

import com.easy.query.core.expression.parser.core.available.TableAvailable;
import com.easy.query.core.proxy.AbstractProxyEntity;
import com.easy.query.core.proxy.SQLColumn;
import com.easy.query.core.proxy.SQLSelectAsExpression;
import com.easy.query.core.proxy.fetcher.AbstractFetcher;
import com.easy.query.core.proxy.core.EntitySQLContext;
import com.easy.query.test.entity.TopicTypeArrayJson;
import com.easy.query.core.proxy.columns.types.SQLStringTypeColumn;
import com.easy.query.core.proxy.columns.types.SQLIntegerTypeColumn;
import com.easy.query.core.proxy.columns.types.SQLAnyTypeColumn;
import com.easy.query.core.proxy.columns.types.SQLLocalDateTimeTypeColumn;

/**
 * this file automatically generated by easy-query, don't modify it
 * 当前文件是easy-query自动生成的请不要随意修改
 * 如果出现属性冲突请使用@ProxyProperty进行重命名
 *
 * @author easy-query
 */
public class TopicTypeArrayJsonProxy extends AbstractProxyEntity<TopicTypeArrayJsonProxy, TopicTypeArrayJson> {

    private static final Class<TopicTypeArrayJson> entityClass = TopicTypeArrayJson.class;

    public static final TopicTypeArrayJsonProxy TABLE = createTable().createEmpty();

    public static TopicTypeArrayJsonProxy createTable() {
        return new TopicTypeArrayJsonProxy();
    }

    public TopicTypeArrayJsonProxy() {
    }

    /**
     * {@link TopicTypeArrayJson#getId}
     */
    public SQLStringTypeColumn<TopicTypeArrayJsonProxy> id() {
        return getStringTypeColumn("id");
    }

    /**
     * {@link TopicTypeArrayJson#getStars}
     */
    public SQLIntegerTypeColumn<TopicTypeArrayJsonProxy> stars() {
        return getIntegerTypeColumn("stars");
    }

    /**
     * {@link TopicTypeArrayJson#getTitle}
     */
    public SQLAnyTypeColumn<TopicTypeArrayJsonProxy, com.easy.query.test.entity.TopicTypeJsonValue> title() {
        return getAnyTypeColumn("title", __cast(Object.class));
    }


    /**
     * {@link TopicTypeArrayJson#getTitle2}
     */
    public SQLAnyTypeColumn<TopicTypeArrayJsonProxy, java.util.List<com.easy.query.test.entity.TopicTypeJsonValue>> title2() {
        return getAnyTypeColumn("title2", __cast(Object.class));
    }


    /**
     * private Integer[] title3;
     * {@link TopicTypeArrayJson#getTopicType}
     */
    public SQLIntegerTypeColumn<TopicTypeArrayJsonProxy> topicType() {
        return getIntegerTypeColumn("topicType");
    }

    /**
     * {@link TopicTypeArrayJson#getCreateTime}
     */
    public SQLLocalDateTimeTypeColumn<TopicTypeArrayJsonProxy> createTime() {
        return getLocalDateTimeTypeColumn("createTime");
    }


    @Override
    public Class<TopicTypeArrayJson> getEntityClass() {
        return entityClass;
    }

    @Override
    public TopicTypeArrayJsonProxy createNew() {
        return createTable();
    }


    /**
     * 数据库列的简单获取
     *
     * @return
     */
    public TopicTypeArrayJsonProxyFetcher FETCHER = new TopicTypeArrayJsonProxyFetcher(this, null, SQLSelectAsExpression.empty);


    public static class TopicTypeArrayJsonProxyFetcher extends AbstractFetcher<TopicTypeArrayJsonProxy, TopicTypeArrayJson, TopicTypeArrayJsonProxyFetcher> {

        public TopicTypeArrayJsonProxyFetcher(TopicTypeArrayJsonProxy proxy, TopicTypeArrayJsonProxyFetcher prev, SQLSelectAsExpression sqlSelectAsExpression) {
            super(proxy, prev, sqlSelectAsExpression);
        }


        /**
         * {@link TopicTypeArrayJson#getId}
         */
        public TopicTypeArrayJsonProxyFetcher id() {
            return add(getProxy().id());
        }

        /**
         * {@link TopicTypeArrayJson#getStars}
         */
        public TopicTypeArrayJsonProxyFetcher stars() {
            return add(getProxy().stars());
        }

        /**
         * {@link TopicTypeArrayJson#getTitle}
         */
        public TopicTypeArrayJsonProxyFetcher title() {
            return add(getProxy().title());
        }

        /**
         * {@link TopicTypeArrayJson#getTitle2}
         */
        public TopicTypeArrayJsonProxyFetcher title2() {
            return add(getProxy().title2());
        }

        /**
         * private Integer[] title3;
         * {@link TopicTypeArrayJson#getTopicType}
         */
        public TopicTypeArrayJsonProxyFetcher topicType() {
            return add(getProxy().topicType());
        }

        /**
         * {@link TopicTypeArrayJson#getCreateTime}
         */
        public TopicTypeArrayJsonProxyFetcher createTime() {
            return add(getProxy().createTime());
        }


        @Override
        protected TopicTypeArrayJsonProxyFetcher createFetcher(TopicTypeArrayJsonProxy cp, AbstractFetcher<TopicTypeArrayJsonProxy, TopicTypeArrayJson, TopicTypeArrayJsonProxyFetcher> prev, SQLSelectAsExpression sqlSelectExpression) {
            return new TopicTypeArrayJsonProxyFetcher(cp, this, sqlSelectExpression);
        }
    }


    public static final class Fields {
        public static final String id = "id";
        public static final String stars = "stars";
        public static final String title = "title";
        public static final String title2 = "title2";
        public static final String topicType = "topicType";
        public static final String createTime = "createTime";

        private Fields() {
        }
    }
}
